/*    */ package system.staros.sblock1;
/*    */ 
/*    */ public class WhileNode extends Node
/*    */ {
/*    */   private Node testCondition;
/*    */   private Node loopBody;
/*    */ 
/*    */   public WhileNode(SourcePosition paramSourcePosition, Node paramNode1, Node paramNode2)
/*    */   {
/* 35 */     super(paramSourcePosition);
/* 36 */     this.testCondition = paramNode1;
/* 37 */     this.loopBody = paramNode2;
/*    */   }
/*    */ 
/*    */   public Node getTestCondition() {
/* 41 */     return this.testCondition;
/*    */   }
/*    */ 
/*    */   public Node getLoopBody() {
/* 45 */     return this.loopBody;
/*    */   }
/*    */ 
/*    */   public ZemObject eval(Interpreter paramInterpreter)
/*    */   {
/* 50 */     ZemObject localZemObject = null;
/* 51 */     while (this.testCondition.eval(paramInterpreter).toBoolean(this.testCondition.getPosition()).booleanValue()) {
/* 52 */       localZemObject = this.loopBody.eval(paramInterpreter);
/*    */     }
/* 54 */     return localZemObject;
/*    */   }
/*    */ 
/*    */   public String toString()
/*    */   {
/* 59 */     StringBuilder localStringBuilder = new StringBuilder();
/* 60 */     localStringBuilder.append('(');
/* 61 */     localStringBuilder.append("while ");
/* 62 */     localStringBuilder.append(this.testCondition);
/* 63 */     localStringBuilder.append(' ');
/* 64 */     localStringBuilder.append(this.loopBody);
/* 65 */     localStringBuilder.append(')');
/* 66 */     return localStringBuilder.toString();
/*    */   }
/*    */ }

/* Location:           D:\Марк\!IMPORTANT\staros\archive\version-2.260.zip
 * Qualified Name:     system.staros.sblock1.WhileNode
 * JD-Core Version:    0.6.1
 */